﻿// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
//
// 本项目主要遵循 MIT 许可证和 Apache 许可证（版本 2.0）进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
//
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动！任何基于本项目二次开发而产生的一切法律纠纷和责任，我们不承担任何责任！

using Admin.NET.Core;
using System.ComponentModel.DataAnnotations;

namespace Admin.NET.Application;

/// <summary>
/// 球队球员申请表基础输入参数
/// </summary>
public class AppTeamPlayerApplyBaseInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    public virtual long? Id { get; set; }
    
    /// <summary>
    /// 球员申请/球队申请
    /// </summary>
    [Dict(nameof(TeamPlayerEnum), AllowNullValue=true)]
    [Required(ErrorMessage = "球员申请/球队申请不能为空")]
    public virtual TeamPlayerEnum? Type { get; set; }
    
    /// <summary>
    /// 球员Id
    /// </summary>
    [Required(ErrorMessage = "球员Id不能为空")]
    public virtual long? UserId { get; set; }
    
    /// <summary>
    /// 球队Id
    /// </summary>
    [Required(ErrorMessage = "球队Id不能为空")]
    public virtual long? TeamId { get; set; }
    
    /// <summary>
    /// 申请状态
    /// </summary>
    [Dict(nameof(ApplicationStatusEnum), AllowNullValue=true)]
    [Required(ErrorMessage = "申请状态不能为空")]
    public virtual ApplicationStatusEnum? Status { get; set; }
    
    /// <summary>
    /// 申请时间
    /// </summary>
    public virtual DateTime? ApplicationDate { get; set; }
    
    /// <summary>
    /// 处理时间
    /// </summary>
    public virtual DateTime? ProcessedDate { get; set; }
    
    /// <summary>
    /// 处理人Id
    /// </summary>
    public virtual long? ProcessedBy { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    public virtual string? Remark { get; set; }
    
}

/// <summary>
/// 球队球员申请表分页查询输入参数
/// </summary>
public class PageAppTeamPlayerApplyInput : BasePageInput
{
    /// <summary>
    /// 球员申请/球队申请
    /// </summary>
    [Dict(nameof(TeamPlayerEnum), AllowNullValue=true)]
    public TeamPlayerEnum? Type { get; set; }
    
    /// <summary>
    /// 球员Id
    /// </summary>
    public long? UserId { get; set; }
    
    /// <summary>
    /// 球队Id
    /// </summary>
    public long? TeamId { get; set; }
    
    /// <summary>
    /// 申请状态
    /// </summary>
    [Dict(nameof(ApplicationStatusEnum), AllowNullValue=true)]
    public ApplicationStatusEnum? Status { get; set; }
    
    /// <summary>
    /// 申请时间范围
    /// </summary>
     public DateTime?[] ApplicationDateRange { get; set; }
    
    /// <summary>
    /// 处理时间范围
    /// </summary>
     public DateTime?[] ProcessedDateRange { get; set; }
    
    /// <summary>
    /// 处理人Id
    /// </summary>
    public long? ProcessedBy { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    public string? Remark { get; set; }
    
    /// <summary>
    /// 选中主键列表
    /// </summary>
     public List<long> SelectKeyList { get; set; }
}

/// <summary>
/// 球队球员申请表增加输入参数
/// </summary>
public class AddAppTeamPlayerApplyInput
{
    /// <summary>
    /// 球员申请/球队申请
    /// </summary>
    [Dict(nameof(TeamPlayerEnum), AllowNullValue=true)]
    [Required(ErrorMessage = "球员申请/球队申请不能为空")]
    public TeamPlayerEnum? Type { get; set; }
    
    /// <summary>
    /// 球员Id
    /// </summary>
    [Required(ErrorMessage = "球员Id不能为空")]
    public long? UserId { get; set; }
    
    /// <summary>
    /// 球队Id
    /// </summary>
    [Required(ErrorMessage = "球队Id不能为空")]
    public long? TeamId { get; set; }
    
    /// <summary>
    /// 申请状态
    /// </summary>
    [Dict(nameof(ApplicationStatusEnum), AllowNullValue=true)]
    [Required(ErrorMessage = "申请状态不能为空")]
    public ApplicationStatusEnum? Status { get; set; }= ApplicationStatusEnum.Pending;

    /// <summary>
    /// 申请时间
    /// </summary>
    public DateTime? ApplicationDate { get; set; }
    
    /// <summary>
    /// 处理时间
    /// </summary>
    public DateTime? ProcessedDate { get; set; }
    
    /// <summary>
    /// 处理人Id
    /// </summary>
    public long? ProcessedBy { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    [MaxLength(256, ErrorMessage = "备注字符长度不能超过256")]
    public string? Remark { get; set; }
    
}

/// <summary>
/// 球队球员申请表删除输入参数
/// </summary>
public class DeleteAppTeamPlayerApplyInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
}

/// <summary>
/// 设置状态输入参数
/// </summary>
public class SeeAppTeamPlayerApplyInput : BaseIdInput
{
    public TeamPlayerEnum Type { get; set; }

    /// <summary>
    /// 申请状态
    /// </summary>
    [Dict(nameof(ApplicationStatusEnum), AllowNullValue = true)]
    [Required(ErrorMessage = "申请状态不能为空")]
    public ApplicationStatusEnum? Status { get; set; }
}

/// <summary>
/// 球队球员申请表更新输入参数
/// </summary>
public class UpdateAppTeamPlayerApplyInput
{
    /// <summary>
    /// 主键Id
    /// </summary>    
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
    /// <summary>
    /// 球员申请/球队申请
    /// </summary>    
    [Dict(nameof(TeamPlayerEnum), AllowNullValue=true)]
    [Required(ErrorMessage = "球员申请/球队申请不能为空")]
    public TeamPlayerEnum? Type { get; set; }
    
    /// <summary>
    /// 球员Id
    /// </summary>    
    [Required(ErrorMessage = "球员Id不能为空")]
    public long? UserId { get; set; }
    
    /// <summary>
    /// 球队Id
    /// </summary>    
    [Required(ErrorMessage = "球队Id不能为空")]
    public long? TeamId { get; set; }
    
    /// <summary>
    /// 申请状态
    /// </summary>    
    [Dict(nameof(ApplicationStatusEnum), AllowNullValue=true)]
    [Required(ErrorMessage = "申请状态不能为空")]
    public ApplicationStatusEnum? Status { get; set; }
    
    /// <summary>
    /// 申请时间
    /// </summary>    
    public DateTime? ApplicationDate { get; set; }
    
    /// <summary>
    /// 处理时间
    /// </summary>    
    public DateTime? ProcessedDate { get; set; }
    
    /// <summary>
    /// 处理人Id
    /// </summary>    
    public long? ProcessedBy { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>    
    [MaxLength(256, ErrorMessage = "备注字符长度不能超过256")]
    public string? Remark { get; set; }
    
}

/// <summary>
/// 球队球员申请表主键查询输入参数
/// </summary>
public class QueryByIdAppTeamPlayerApplyInput : DeleteAppTeamPlayerApplyInput
{
}

/// <summary>
/// 下拉数据输入参数
/// </summary>
public class DropdownDataAppTeamPlayerApplyInput
{
    /// <summary>
    /// 是否用于分页查询
    /// </summary>
    public bool FromPage { get; set; }
}

/// <summary>
/// 球队球员申请表数据导入实体
/// </summary>
[ExcelImporter(SheetIndex = 1, IsOnlyErrorRows = true)]
public class ImportAppTeamPlayerApplyInput : BaseImportInput
{
    /// <summary>
    /// 球员申请/球队申请
    /// </summary>
    [ImporterHeader(Name = "*球员申请/球队申请")]
    [ExporterHeader("*球员申请/球队申请", Format = "", Width = 25, IsBold = true)]
    public TeamPlayerEnum? Type { get; set; }
    
    /// <summary>
    /// 球员Id 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? UserId { get; set; }
    
    /// <summary>
    /// 球员Id 文本
    /// </summary>
    [ImporterHeader(Name = "*球员Id")]
    [ExporterHeader("*球员Id", Format = "", Width = 25, IsBold = true)]
    public string UserFkDisplayName { get; set; }
    
    /// <summary>
    /// 球队Id 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? TeamId { get; set; }
    
    /// <summary>
    /// 球队Id 文本
    /// </summary>
    [ImporterHeader(Name = "*球队Id")]
    [ExporterHeader("*球队Id", Format = "", Width = 25, IsBold = true)]
    public string TeamFkDisplayName { get; set; }
    
    /// <summary>
    /// 申请状态
    /// </summary>
    [ImporterHeader(Name = "*申请状态")]
    [ExporterHeader("*申请状态", Format = "", Width = 25, IsBold = true)]
    public ApplicationStatusEnum? Status { get; set; }
    
    /// <summary>
    /// 申请时间
    /// </summary>
    [ImporterHeader(Name = "申请时间")]
    [ExporterHeader("申请时间", Format = "", Width = 25, IsBold = true)]
    public DateTime? ApplicationDate { get; set; }
    
    /// <summary>
    /// 处理时间
    /// </summary>
    [ImporterHeader(Name = "处理时间")]
    [ExporterHeader("处理时间", Format = "", Width = 25, IsBold = true)]
    public DateTime? ProcessedDate { get; set; }
    
    /// <summary>
    /// 处理人Id 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? ProcessedBy { get; set; }
    
    /// <summary>
    /// 处理人Id 文本
    /// </summary>
    [ImporterHeader(Name = "处理人Id")]
    [ExporterHeader("处理人Id", Format = "", Width = 25, IsBold = true)]
    public string ProcessedByFkDisplayName { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    [ImporterHeader(Name = "备注")]
    [ExporterHeader("备注", Format = "", Width = 25, IsBold = true)]
    public string? Remark { get; set; }
    
}
